<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <script type="text/javascript" src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script>


</head>
<body>
<div id="app">
    <img :src="img" v-on:click="clickImg"
         @mouseover="changeImg($event, 'b.png')"
         @mouseleave="changeImg($event, 'c.png')" alt="美女">
</div>

<script>
let app = new Vue({
    el: '#app',
    data: {
        img: 'a.png'
    },
    methods: {
    clickImg: function (event) {
        console.log(event);
        console.log(event.currentTarget);
        },
    changeImg: function (event, name) {
        console.log(event);
        console.log(name);
        }
    }
});


</script>

</body>
</html>
